package cn.demoxy.shiro;

import org.apache.shiro.subject.Subject;
import org.apache.shiro.subject.SubjectContext;
import org.apache.shiro.web.mgt.DefaultWebSubjectFactory;

/**
 * @auther demo
 * @date 2022/6/20 10:39
 */
public class JwtDefaultSubjectFactory extends DefaultWebSubjectFactory {
    @Override
    public Subject createSubject(SubjectContext context) {
        // 不创建 session,禁止使用session
        context.setSessionCreationEnabled(false);
        return super.createSubject(context);
    }
}
